#pragma once

#include <cyber/cyber.h>
#include <memory>

template <typename MessageT>
class CyberrtWriter
{
public:
    CyberrtWriter(const std::shared_ptr<apollo::cyber::Writer<MessageT>> &writer) : m_writer(writer)
    {
    }

public:
    bool write(const std::shared_ptr<MessageT> &msg_ptr)
    {
        return m_writer->Write(msg_ptr);
    }

private:
    const std::shared_ptr<apollo::cyber::Writer<MessageT>> m_writer;
};